This is the code used for generating live stats for the 2023 PACE NSC. It used a tweaked version of MODAQ as QBJ input. This is rather janky in places, as a decent amount of this was written at the last second, and it's designed only to work with this one tournament. That being said, I do think there is potential if anyone wants to improve on this and perhaps make something that would more easily (and less buggily) work with other events.
MODAQ calls readgame.php, which outputs .qbj files to the /qbj folder and smaller .json files to the /json folder. For the NSC, I ran processgames.py once every ~10 seconds, which took the .json files and created most of the live stats page at livestats.html. Finally, a user at index.html would make an Ajax request to reload the live stats, which would automatically refresh.